#ifndef DELI_H
#define DELI_H

#include <iostream>
#include <string.h>
#include "node.h"
#include "Customer_Obj.h"
#include "sync.h"
#include "control.h"
#include "sweeps.h"
//#include "Customer_Obj.cpp"
using namespace std;

class Deli {
        public:
                Deli(); // initialize linked list to empty
                Deli(sync *sync_object, control *control_object, sweeps *sweeps_object);
                ~Deli();
                node *head;
                node *tail;
                bool isEmpty();               
                void insert(Customer_Obj c); 
                Customer_Obj remove(); 		
                void setTimeInLine(int t);
                Customer_Obj peek();
                int getTimeInLine();
				void setStats();
				int getAverageTime();
				int getLongestWait();
				int getNumServed();
				void show_stats();
				int timeArrayCounter;


        private:
                int timeInLine;
                int arrivalTime;
                int position;
                string firstName;
                string lastName;
                string fullName;
                node *current_index;
                void start();
                bool isElement();
                void advance();
                Customer_Obj current();
                sync *sync_obj;
                control *control_obj;
                sweeps *sweeps_obj;
				int averageTime;
				int numServed;
				int longestWait;
				int served;
				int timeArray[1000];
};
#endif
